﻿<%@ Page Title="" Language="C#" MasterPageFile="~/UserCentents/Centents.Master" AutoEventWireup="true"
    CodeBehind="AddMember.aspx.cs" Inherits="School.UserCentents.AddMember" %>

<asp:Content ID="Content1" ContentPlaceHolderID="ContentPlaceHolder1" runat="server">
    <script>
        function Check() {
            if (document.getElementById("ContentPlaceHolder1_txtLoginName").value == "") {
                alert('用户名不能为空');
                return false;
            }

            var str = /^[A-Za-z0-9]+$/;
            var txtSN1 = document.getElementById("ContentPlaceHolder1_txtLoginName").value;
            if (str.test(txtSN1) == false) {
                alert('用户名只能输入数字和26个英文字母');
                return false;
            }

            if (document.getElementById("ContentPlaceHolder1_txtName").value == "") {
                alert('昵称不能为空');
                return false;
            }

            var str1 = /^[1][358]\d{9}$/;
            var txtSN = document.getElementById("ContentPlaceHolder1_txtPhone").value;
            if (txtSN != "") {
                if (str1.test(txtSN) == false) {
                    alert('请输入正确的手机号');
                    return false;
                }
            }

            return true;
        }
    </script>
    <div id="MainBody">
        <!-- 右侧开始 -->
        <div class="mainHeader">
            <div class="itopic">
                <img src="../images/body_side_icon_qzadd.gif">添加新用户</div>
            <div class="iclass">
            </div>
            <div class="clear">
            </div>
        </div>
        <div class="mainBodyShow">
            <div id="upphoto">
                <table border="0" cellspacing="0" id="UploadPhoto">
                    <tbody>
                        <tr>
                            <td class="LabelTitle">
                                用户组：
                            </td>
                            <td class="LabelShow">
                                <asp:RadioButtonList ID="RadioButtonList1" runat="server" RepeatDirection="Horizontal">
                                </asp:RadioButtonList>
                            </td>
                        </tr>
                        <tr id="XueXiao" runat="server" visible="false">
                            <td class="LabelTitle">
                                校区：
                            </td>
                            <td class="LabelShow">
                                <asp:DropDownList ID="DropDownList1" runat="server" Height="20px" Width="168px">
                                </asp:DropDownList>
                            </td>
                        </tr>
                        <tr>
                            <td class="LabelTitle">
                                用户名：
                            </td>
                            <td class="LabelShow">
                                <asp:TextBox runat="server" ID="txtLoginName" CssClass="input" Width="250px"></asp:TextBox>
                                登录账号名
                            </td>
                        </tr>
                        <tr>
                            <td class="LabelTitle">
                                昵称：
                            </td>
                            <td class="LabelShow">
                                <asp:TextBox runat="server" ID="txtName" CssClass="input" Width="250px"></asp:TextBox>
                                显示名字，例如使用真实姓名或某某家长
                            </td>
                        </tr>
                        <tr>
                            <td class="LabelTitle">
                                性别：
                            </td>
                            <td class="LabelShow">
                                <asp:RadioButtonList ID="RadioButtonList2" runat="server" RepeatDirection="Horizontal">
                                    <asp:ListItem Value="1" Selected>男</asp:ListItem>
                                    <asp:ListItem Value="0">女</asp:ListItem>
                                </asp:RadioButtonList>
                            </td>
                        </tr>
                        <tr>
                            <td class="LabelTitle">
                                手机：
                            </td>
                            <td class="LabelShow">
                                <asp:TextBox runat="server" ID="txtPhone" CssClass="input" Width="250px"></asp:TextBox>
                            </td>
                        </tr>
                        <tr>
                            <td class="LabelTitle">
                                登录密码：
                            </td>
                            <td class="LabelShow">
                                <asp:TextBox runat="server" ID="txtPWD" TextMode="Password" CssClass="input" Width="250px"
                                    autocomplete="off"></asp:TextBox>
                                <span></span>
                            </td>
                        </tr>
                        <%--<tr id="ensms">
                            <td class="LabelTitle">
                                短信权限：
                            </td>
                            <td class="LabelShow">
                                <input type="radio" name="emailValid" id="emailValid" value="0" checked="">否&nbsp;<input
                                    type="radio" name="emailValid" id="emailValid" value="1">是 （是否可以发送手机短信）
                            </td>
                        </tr>--%>
                        <tr>
                            <td class="LabelTitle">
                            </td>
                            <td class="LabelShow" id="idMsg">
                                <asp:Button ID="Button1" runat="server" Text="提交" OnClick="Button1_Click" OnClientClick="return Check()" />
                            </td>
                        </tr>
                    </tbody>
                </table>
            </div>
        </div>
        <!-- 右侧结束 -->
    </div>
</asp:Content>
